﻿
<div id="flashContent"></div>

<% if user_signed_in? %>

  <%= javascript_include_tag "swfobject", :cache => true %>
  <script type="text/javascript">
    
    var swfVersionStr = "10.0.0";
    
    var xiSwfUrlStr = "/swf/playerProductInstall.swf";
    var flashvars = {
        novice: "false",
        show_signin: true,
        /* show_signup: , */
        base_url: "http://localhost:3000"
    };
    var params = {
        quality: "high",
        bgcolor: "#FFFFFF",
        allowscriptaccess: "sameDomain",
        allowfullscreen: "true"
    };
    var attributes = {
        id: "Elfin",
        name: "Elfin",
        align: "middle"
    };
    swfobject.embedSWF(
        "/swf/production/elfin/Elfin.swf", "flashContent", 
        "760", "450", 
        swfVersionStr, xiSwfUrlStr, 
        flashvars, params, attributes);
        
    swfobject.createCSS("#flashContent", "display:block;text-align:left;");
    
  </script>
  
<% else %>

  <p>????? ??????? "login"!</p>
  <h1>Welcome</h1>
  <p>Here will be text how powerful, easy and light elfin is!</p>

  <p>Main aim is to induce you to login :) <%= link_to "Just try to do it!", index_path %></p>

  <p>хуй!</p>
<% end %>